<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\Facades\DB;

return new class extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('app_qa', function (Blueprint $table) {
            $table->id();
            $table->string('title')->comment("标题");
            $table->text('content')->comment("内容");
            $table->unsignedSmallInteger('order')->comment("排序");
            $table->timestamps();
        });
        DB::statement("ALTER TABLE `app_qa` COMMENT='常见问题'");
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('app_qa');
    }
};
